import request from "@/utils/request";

// 查询床位信息列表
export function listBed(query) {
  return request({
    url: "/system/bed/list",
    method: "post",
    data: query,
  });
}

// 查询床位信息详细
export function getBed(id) {
  return request({
    url: `/system/bed/${id}`,
    method: "get",
  });
}

// 新增床位信息
export function addBed(data) {
  return request({
    url: "/system/bed/add",
    method: "post",
    data: data,
  });
}

// 修改床位信息
export function updateBed(data) {
  return request({
    url: "/system/bed/edit",
    method: "post",
    data: data,
  });
}

// 删除床位信息
export function delBed(id) {
  return request({
    url: "/system/bed/remove",
    method: "post",
    data: { id: id },
  });
}

// 导出床位信息
export function exportBed(query) {
  return request({
    url: "/system/bed/export",
    method: "post",
    data: query,
  });
}
